package com.iss.card.view.model;

import android.util.Log;

import com.iss.card.webservice.BaseModel;

public class CardHistoryBrowseModel extends BaseModel {

	/*
	 * (non-Javadoc)
	 * @see com.iss.card.webservice.BaseModel#addValues(java.lang.String, java.lang.String, com.iss.card.webservice.BaseModel)
	 * storeId: store id
storeName:the name of the store name
storeAddress: store address where user can consume
storeLatitude: store latitude
storeLongitude: store longitude
	 */
	
	
	private String storeId;
	private String storeName;
	private String storeAddress;
	private String storeLatitude;
	private String storeLongitude;
	
	private final static String  STORE_ID= "storeId";
	private final static String  STORE_NAME = "storeName";// unuse
	private final static String  STORE_ADDRESS = "storeAddress";
	private final static String  STORE_LATITUDE = "storeLatitude";
	private final static String  STORE_LONGTITUDE = "storeLongitude";
	
	
	/**
	 * 
	 * 05-23 01:54:49.336: D/kitexy debug(1831): history tempString ===> storeId
05-23 01:54:49.336: D/kitexy debug(1831): history valueString ===> 1
05-23 01:54:49.336: D/kitexy debug(1831): history tempString ===> storeAddress
05-23 01:54:49.347: D/kitexy debug(1831): history valueString ===> 无锡市崇安区 广益路289号哥伦布广场一期
05-23 01:54:49.347: D/kitexy debug(1831): history tempString ===> storeLatitude
05-23 01:54:49.347: D/kitexy debug(1831): history valueString ===> 31.598387
05-23 01:54:49.347: D/kitexy debug(1831): history tempString ===> storeLongitude
05-23 01:54:49.347: D/kitexy debug(1831): history valueString ===> 120.342714

	 */
	@Override
	public void addValues(String tempString, String valueString,
			BaseModel baseMode) {
		
		/*Log.d("kitexy debug", "history tempString ===> " + tempString);
		Log.d("kitexy debug", "history valueString ===> " + valueString);*/

		if(tempString == STORE_ID){
			setStoreId(valueString);
		}else if(tempString == STORE_NAME){
			setStoreName(valueString);
		}else if(tempString == STORE_ADDRESS){
			setStoreAddress(valueString);
		}else if(tempString == STORE_LATITUDE){
			setStoreLatitude(valueString);
		}else if(tempString == STORE_LONGTITUDE){
			setStoreLongitude(valueString);
		}
		baseMode = this;
	}
	
	public void setStoreId(String storeId){
		this.storeId = storeId;
	}
	public void setStoreName(String storeName){
		this.storeName = storeName;
	}
	public void setStoreAddress(String storeAddress){
		this.storeAddress = storeAddress;
	}
	public void setStoreLatitude(String storeLatitude){
		this.storeLatitude = storeLatitude;
	}
	public void setStoreLongitude(String storeLongitude){
		this.storeLongitude = storeLongitude;
	}

	public String getStoreId(){
		return storeId;
	}
	public String getStoreName(){
		return storeName;
	}
	public String getStoreAddress(){
		return storeAddress;
	}
	public String getStoreLatitude(){
		return storeLatitude;
	}
	public String getStoreLongitude(){
		return storeLongitude;
	}
}
